import { createRouter, createWebHashHistory } from 'vue-router'
import List from '../views/List.vue'
let router = createRouter({
    history: createWebHashHistory(),
    routes: [
        { path: '/', redirect: '/list' },
        { path: 'list', componen: List }
    ]
})
/* 路由的前置守卫 */
router.beforeEach((rto,from,next)=>{
    console.log(to.path,from.path)
    next()  
})
export default router